1. Field of the Invention
The present invention relates to an autofocus control in an imaging device such as a camera.
2. Description of Related Art
A contrast system and a color distortion system are known as a method of autofocus incorporated in a digital video camera or the like. In the contrast system, contrasts of a photographed image are detected, the contrasts at respective positions are compared, and a position where the focus of a lens coincides with a subject is determined. In order to use this method, it is necessary to detect the lens position where the contrast becomes maximum.
In the color distortion system, the focal position of a lens varies according to R (Red), G (Green) and B (Blue) components of light, and this is used to detect a focusing position based on comparison results of magnitudes of high frequency components of the respective colors (JP-A-2009-103800).
In a video camera, since a red LED (wavelength 700 nm) or the like is generally used as an auxiliary light source, an out-of-focus occurs due to the color distortion of a lens. A camera microcomputer performs focus correction at the time of red LED light emission, so that a sharp focus is obtained at the time of strobe main light emission. In the system using the strobe incorporating the AF assist light for still image photography in a dark place as stated above, there is also a method in which the AF assist light (red LED, wavelength 700 nm) is made to emit light in focusing by autofocus, and focus correction is performed (JP-A-11-174521).
A lens has a feature that near infrared light is captured in addition to visible light. However, a filter to cut the near infrared light which is not seen by human eyes is used, so that only the visible light can form an image. A green component is the center wavelength of the visible light, and an image to be photographed often has an average RGB contrast. Thus, focus adjustment is often performed based on the green component. In the method of performing the focus adjustment based on the green component, an original video signal is not directly used as a video signal which is used when a contrast signal is generated. A video signal is used which is changed by changing gains for red, green and blue for the respective RGB components of the original video signal. The gain for green used in this conversion is made larger than the gain for red and the gain for blue, and the ratio of the green component is made large. In general, the conversion equation is expressed by the following equations.luminance of red component of video signal after conversion=gain for red×luminance of red component of original video signal   (1)luminance of green component of video signal after conversion=gain for green×luminance of green component of original video signal   (2)luminance of blue component of video signal after conversion=gain for blue×luminance of blue component of original video signal   (3)luminance=0.3 R (brightness of red luminance)+0.59 G (brightness, of green luminance)+0.11 B (brightness of blue luminance)   (4)
Here, in general, the ratio is made gain for red:gain for green:gain for blue=0.3:0.59:0,11, and 0.3 is used as the gain for red, 0.59 is used as the gain for green, and 0.11 is used as the gain for blue (or 0.9, 1.77 and 0.33 obtained by multiplying the respective values by 3 are used). A contrast signal is generated by using the video signal after conversion, and the lens position where the contrast signal becomes maximum is detected and focusing is performed.
When this method is used, since a complicated calculation is not required to be performed, calculation time becomes short. Thus, this method is used for many lenses. Besides, the reason why focusing is performed based on green is that, since the human sensitivity becomes maximum at approximately the green component, there is also an intension to perform focusing based on the component close to the maximum human sensitivity.
An infrared rays cut filter 27 is a filter that allows visible light to pass through and cuts near infrared light. The infrared rays cut filter 27 is turned OFF and the near infrared light is captured, so that a red component becomes large in an image captured by a camera. However, when focus correction is performed by such a method, the red component becomes large when the infrared rays cut filter is OFF (when the infrared rays cut filter is removed). Thus, when focus correction is performed based on the green component, out-of-focus occurs, and the image can become blurred. The remarkable example appears when the infrared rays cut filter is removed.
FIG. 2 is an image view of a focus position. Since the focal position of the green component is the center of RGB, in a normal image, it is appropriate if focusing is adjusted at the position of a focal distance (G) 41 based on green light. However, when an image containing a large red component is captured as in the case where the infrared rays cut filter is removed, it is appropriate if focusing is adjusted at a focal distance (R) 40. However, in the related art method, since focusing is adjusted at the focal distance (G) 41, out-of-focus occurs, and the image becomes blurred.
Besides, there are problems also in the cost and system, and there is also a case where it is difficult to, incorporate an assist light and the like into the autofocus.